<script setup lang="ts">
import { ref } from 'vue'

// 从多环境配置文件中获取 Swagger UI 地址
const swaggerUrl = ref<string>(import.meta.env.VITE_SWAGGER_URL as string)
</script>

<template>
  <div class="swagger-container">
    <iframe
      class="swagger-iframe"
      :src="swaggerUrl"
      frameborder="0"
      scrolling="auto"
    />
  </div>
</template>

<style scoped>
.swagger-container {
  width: 100%;
  height: 100vh;
  overflow: hidden;
}
.swagger-iframe {
  width: 100%;
  height: 100%;
  border: none;
}
</style>
